package com.atguigu.gmall.service;

import com.atguigu.gmall.entity.PrepareSeckillOrder;
import com.atguigu.gmall.entity.SeckillProduct;
import com.atguigu.gmall.entity.UserSeckillSkuInfo;
import com.atguigu.gmall.result.RetVal;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

public interface SeckillService extends IService<SeckillProduct> {

    List<SeckillProduct> findSeckillProduct();

    SeckillProduct getSeckillProductBySkuId(Long skuId);

    boolean checkSeckillProductStatusBySkuId(Long skuId);

    void sendRabbitMqMessage(String userId, Long skuId);

    void prepareSeckill(UserSeckillSkuInfo userSeckillSkuInfo);

    RetVal hasQualified(Long skuId, String userId);

    PrepareSeckillOrder getseckillPrepareOrderInfoByUserId(String userId);

    void deletePrepareSeckillOrder(String userId , Long orderId);
}
